import React from 'react'
import { Button } from 'antd'
import { count, countObj, addCount } from 'utils/index'
function ModulePage() {
    const handleClick = () => {
        addCount()
        console.log('handleClick:', count);
    }
    const handleClick2 = () => {
        countObj.count++
        console.log('handleClick2:', countObj);
    }
    return (
        <div className='module-page'>

            <span>{count}</span>
            <Button onClick={handleClick}>增加</Button>
            <span>{countObj.count}</span>
            <Button onClick={handleClick2}>直接修改</Button>
        </div>
    )
}

export default ModulePage
